Skip to content

add CPP standard CI workflow with cppcheck support#169

Merged
yannS2016 merged 4 commits intopcdshub:masterfrom
yannS2016:cpp-standard
Apr 6, 2026
Merged

add CPP standard CI workflow with cppcheck support#169
yannS2016 merged 4 commits intopcdshub:masterfrom
yannS2016:cpp-standard

Conversation

@yannS2016
Copy link
Copy Markdown
Contributor

Add reusable cpp-standard.yml workflow for C++ projects, mirroring the TwinCAT standard workflow pattern. Add install-cppcheck boolean input (default: false) to pre-commit.yml so C++ workflows can ensure cppcheck is available on the runner before running pre-commit hooks.

Add reusable cpp-standard.yml workflow for C++ projects, mirroring the
TwinCAT standard workflow pattern. Add `install-cppcheck` boolean input
(default: false) to pre-commit.yml so C++ workflows can ensure cppcheck
is available on the runner before running pre-commit hooks.
@yannS2016 yannS2016 requested a review from a team as a code owner March 31, 2026 20:12
@yannS2016 yannS2016 requested a review from ZLLentz March 31, 2026 20:12
Copy link
Copy Markdown
Member

@ZLLentz ZLLentz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good addition to the central workflows

One consideration: in pre-commit.yml, should this be a more generic install step instead?

Some of the other workflows have a system-packages input.

- name: Install required system packages
if: inputs.system-packages != ''
run: |
sudo apt-get update
sudo apt-get -y install ${{ inputs.system-packages }}

Yann Stephen Mandza added 2 commits April 4, 2026 08:03
Replaced the C++-specific `install-cppcheck` boolean input with a generic
`system-packages` string input in pre-commit.yml.Updated cpp-standard.yml to
pass `system-packages: "cppcheck"` accordingly.
Copy link
Copy Markdown
Member

@ZLLentz ZLLentz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm fully 👍 on this

Copy link
Copy Markdown
Contributor

@tangkong tangkong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this as well. This makes our pre-commit setups more flexible across the board

@yannS2016 yannS2016 merged commit a012ec9 into pcdshub:master Apr 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants